<%@ page language="java" import="java.util.*" pageEncoding="utf-8"%>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>
<!doctype html>
<html lang="en"><head>
    <meta charset="utf-8">
    <title>商品详细信息</title>
    <meta content="IE=edge,chrome=1" http-equiv="X-UA-Compatible">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <meta name="description" content="">
    <meta name="author" content="">

    <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700' rel='stylesheet' type='text/css'>
    <link rel="stylesheet" type="text/css" href="<%=basePath%>lib/bootstrap/css/bootstrap.css">
    <link rel="stylesheet" href="<%=basePath%>lib/font-awesome/css/font-awesome.css">

    <script src="lib/jquery-1.11.1.min.js" type="text/javascript"></script>

    

    <link rel="stylesheet" type="text/css" href="<%=basePath%>stylesheets/theme.css">
    <link rel="stylesheet" type="text/css" href="<%=basePath%>stylesheets/premium.css">


     <!-- Demo page code -->

    <script type="text/javascript">
        $(document).ready(function() {
           $("#goodnumplus").click(function(){
              var num = $("#goodnum").val();
              num++;
              alert(num)
              $("#goodnum").val(num);
            });

            $("#goodnummin").click(function(){
              var num = $("#goodnum").val();
              num--;
              $("#goodnum").val(num);
            });
                
        });
    </script>
    <style type="text/css">
        #line-chart {
            height:300px;
            width:800px;
            margin: 0px auto;
            margin-top: 1em;
        }
        .navbar-default .navbar-brand, .navbar-default .navbar-brand:hover { 
            color: #fff;
        }



    </style>

   


</head>
<body class=" theme-blue">

   

    <div class="navbar navbar-default" role="navigation"  >
        <div class="navbar-header"  >
          <a class="" href="index.html"><span class="navbar-brand" style=""><i class="fa fa-list" style="margin-right:30px; font-size:19px;"></i>商品详细信息</span></a></div>

        <div class="navbar-collapse collapse" style="height: 1px;">

        </div>
      </div>
    </div>
    


    <div class="dialog" style="margin-top:110px;">
        <div class="panel panel-default">
            <p class="panel-heading no-collapse" style="letter-spacing:2px;"> 商品详细信息 </p>
            <div class="panel-body">
                <form action="/u/${gid}/add" method="post">
                    <div class="form-group">
                    	
                        <label>商品名称</label>
                        <input type="text"  value="${goods.gname }" class="form-control span12" readOnly="true" >
                    </div>
                    <div class="form-group">
                        <label>商品单价</label>
                        <input type="text"  value="${goods.gnum }" class="form-control span12" readOnly="true" >
                    </div>
                    <div class="form-group">
                        <label>商品库存</label>
                        <input type="text"  value="${goods.gprice }" class="form-control span12" readOnly="true" >
                    </div>
                    <div class="form-group">
                        <label>购买数量</label>
                        <input id="goodnum" name="cgoodsnum" type="text" class="form-control span12"  value="1">
                    </div>
                    <div class="form-group">
                        <label>支付金额</label>
                        <input type="text" class="form-control span12" readOnly="true" > 
                    </div>
                    <div class="form-group">
                    <a href="/u/${user.uid}/home"><button type="button" class="btn btn-default pull-left">返回</button></a>
                    <input  type="submit" class="btn btn-info pull-right" value="加入购物车">
                    
                </form>
            </div>
        </div>
    </div>

    
    
  
</body></html>
